package com.sanyue.dualPointer;

import org.junit.Test;

import java.util.ArrayList;
import java.util.List;

/**
 * @author sanyue
 * @version 1.0
 * @description: TODO-15三数之和为0
 * @date 2022/1/23 下午2:32
 */
public class ThreeSum {
    @Test
    public void solve(){
        List<List<Integer>> lists = threeSum(new int[]{-1,0,1,2,-1,-4});
        for (int i = 0; i < lists.size(); i++) {
            for (int i1 = 0; i1 < lists.get(i).size(); i1++) {
                System.out.println("i:"+i1);
            }
        }
    }
    public List<List<Integer>> threeSum(int[] nums) {
        List<List<Integer>> anss = new ArrayList<>();


        return anss;
    }

    @Test
    public void testIsPalindrome(){
        boolean bool = isPalindrome(121);
        System.out.println(bool);
    }
    public boolean isPalindrome(int x) {
        //System.out.println(new StringBuilder().append(x));
        return new StringBuilder(""+x).reverse().toString().equals(""+x);
    }

}
